package main

import (
	"flag"
	"fmt"
	"os"
	"path/filepath"
	"strings"
)

func main() {
	// go run .\main.go --name=2
	fmt.Println(os.Args[1:])

	var name string
	flag.StringVar(&name, "name", "czc", "name to be printed")
	output := flag.String("output", "", "output file name; default srcdir/<type>_string.go")
	typeNames := flag.String("type", "", "comma-separated list of type names; must be set")
	doc := flag.Bool("doc", false, "如果为 true, 则仅以 markdown 格式生成错误代码文档")
	flag.Parse()
	fmt.Println(flag.Args())
	fmt.Println(name)

	fmt.Println(os.Args)
	fmt.Println(filepath.Dir(os.Args[0]))

	fmt.Println(1111, *output, *doc, *typeNames)

	z := 2
	u := 4

	fmt.Println(z & u)

	fmt.Println(strings.TrimPrefix("INFOczc", "INFO"))
}
